package com.ac.api.group.vo;

import com.ac.api.group.entity.AcAction;
import io.swagger.annotations.ApiModel;
import io.swagger.annotations.ApiModelProperty;
import lombok.Data;
import org.springframework.beans.BeanUtils;

/**
 * @Author mzl.
 */
@Data
@ApiModel
public class GroupTypeActionVo {

    @ApiModelProperty("功能Id")
    private Integer actionid;

    @ApiModelProperty(value = "功能名称")
    private String actionname;

    @ApiModelProperty(value = "功能编码")
    private String actioncode;

    @ApiModelProperty(value = "描述说明")
    private String description;

    @ApiModelProperty(value = "排序号")
    private Integer actionnumber;

    @ApiModelProperty(value = "访问链接")
    private String link;

    @ApiModelProperty("图标")
    private String icon;

    public GroupTypeActionVo() {
    }

    public GroupTypeActionVo(AcAction acAction) {
        if (null != acAction) {
            BeanUtils.copyProperties(acAction, this);
            this.actionid = acAction.getId();
            this.actionname = acAction.getName();
            this.actioncode = acAction.getAction();
        }
    }

}
